<%@ page contentType="text/html; charset=utf-8"%>
<div>
	<button id="saveBtn">
		保存
	</button>
	<button id="usersBtn">
		所有用户
	</button>
</div>
<div style="margin-top:100px;margin-left:20px;">
	名称
	<input name="name" type="text" id="name" value="${bean.name}" />
</div>
<script language="javascript">
	$(function() {
        $("#saveBtn").click(function(){
        	saveRole();
        }).button();
        $("#usersBtn").click(function(){
        	
        }).button();
	});
	function saveRole() {
		if($("#name").val()=="")return;
		var act = "${param.action}";
		var postdata = 'bean.name=' + $("#name").val() + "&bean.id=${bean.id}";
		$.blockUI({"message":"正在处理...."});
		$.ajax({
			type : "POST",
			url : navObj.admin.role.core+act,
			data : postdata,
			success : function(msg) {
				$.unblockUI();
			}
		});
	}
</script>